package com.carefree.bookmall.entity;

import java.io.Serializable;
import java.util.Objects;

/**
 * 角色
 *
 * @author qianyue
 * @email qianyue1226@gmail.com
 * @date 2022-03-21 20:11:28
 */
public class Role implements Serializable {
    private static final long serialVersionUID = 1L;

    /**
     * id
     */
    private Integer id;
    /**
     * 用户名
     */
    private String roleName;
    /**
     * 备注
     */
    private String mark;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getRoleName() {
        return roleName;
    }

    public void setRoleName(String roleName) {
        this.roleName = roleName;
    }

    public String getMark() {
        return mark;
    }

    public void setMark(String mark) {
        this.mark = mark;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (! (o instanceof Role)) return false;
        Role role = (Role) o;
        return Objects.equals(getId(), role.getId()) && Objects.equals(getRoleName(), role.getRoleName()) && Objects.equals(getMark(), role.getMark());
    }

    @Override
    public int hashCode() {
        return Objects.hash(getId(), getRoleName(), getMark());
    }

    @Override
    public String toString() {
        return "Role{" +
                "id=" + id +
                ", roleName='" + roleName + '\'' +
                ", mark='" + mark + '\'' +
                '}';
    }
}
